﻿<Window x:Class="Resn.WhuPub.WPFClientUI.UpdateTravelFlowWindow"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      Style="{StaticResource WindowStyle}" WindowStartupLocation="CenterScreen"
        Loaded="Window_Loaded" MouseDown="Window_OnMouseDown">
        <Grid Name="LayoutRoot">
                <Grid.RowDefinitions>
                        <RowDefinition Height="Auto" />
                        <RowDefinition />
                        <RowDefinition Height="Auto" />
                </Grid.RowDefinitions>

                <Grid Background="{StaticResource TitleGridColor}">
                        <TextBlock Text="新建差旅" Style="{DynamicResource BigTextBlockStyle}" />
                </Grid>
                <Grid Grid.Row="1" Background="{StaticResource ContentGridColor}">
                        <Grid.RowDefinitions>
                                <RowDefinition Height="*" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="*" />
                        </Grid.RowDefinitions>
                        <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="*" />
                                <ColumnDefinition Width="Auto" />
                                <ColumnDefinition Width="Auto" />
                                <ColumnDefinition Width="*" />
                        </Grid.ColumnDefinitions>
                        <TextBlock Grid.Column="1" Grid.Row="1" HorizontalAlignment="Right" Text="差旅计划"
                                    VerticalAlignment="Top" />
                        <TextBox Grid.Column="2" Grid.Row="1" 
                                 Text="{Binding TravelFlowPlanContent, UpdateSourceTrigger=PropertyChanged}"
                                 Width="640" Name="PlanTextBox" Height="280" />

                        <TextBlock Grid.Column="1" Grid.Row="2" HorizontalAlignment="Right" Text="借款金额"
                                    />
                        <TextBox Grid.Column="2" Grid.Row="2" Name="LendComboBox" Text="{Binding UpdateSourceTrigger=PropertyChanged, StringFormat=\{0:c\}, Path=TravelFlowLendAmount}"
                                  />
                        
                        <TextBlock Grid.Column="1" Grid.Row="3" HorizontalAlignment="Right" Text="开始时间"
                                   VerticalAlignment="Center"  />
                        <DatePicker Grid.Column="2" Grid.Row="3" HorizontalAlignment="Stretch"
                                 Name="StartTimeDatePicker" VerticalAlignment="Center"
                                 Text="{Binding UpdateSourceTrigger=PropertyChanged, StringFormat=\{0:D\}, Path=TravelFlowStartTime, Mode=TwoWay}" Margin="6" Height="30">
                        </DatePicker>
                        
                        <TextBlock Grid.Column="1" Grid.Row="4" HorizontalAlignment="Right" Text="结束时间"
                                   VerticalAlignment="Center"  />
                        <DatePicker Grid.Column="2" Grid.Row="4"
                                 Name="EndTimeDatePicker" VerticalAlignment="Center"
                                 Text="{Binding UpdateSourceTrigger=PropertyChanged, StringFormat=\{0:D\}, Path=TravelFlowEndTime, Mode=TwoWay}" Margin="6" Height="30" />

                        <TextBlock Grid.Column="1" Grid.Row="5" HorizontalAlignment="Right" Text="流程状态"/>
                        <ComboBox Grid.Column="2" Grid.Row="5" />
                </Grid>
                <Grid Grid.Row="2" Background="{StaticResource ContentGridColor}">
                        <Grid.ColumnDefinitions>
                                <ColumnDefinition />
                                <ColumnDefinition Width="Auto" />
                                <ColumnDefinition Width="Auto" />
                        </Grid.ColumnDefinitions>
                        <Button Grid.Column="1" Style="{DynamicResource WindowCancelButtonStyle}"/>
                        <Button Grid.Column="2" Style="{DynamicResource WindowAcceptButtonStyle}" Click="AcceptButton_Click" />
                </Grid>
        </Grid>
</Window>